import request from '@/utils/request';

/**
 * 获取搜索列表
 * @param data
 * @returns
 */
export const getSearchList = (params?) => {
    return request.post('/search/list', params)
}


/**
 * 新增搜索关键字到历史
 * @param data
 * @returns
 */
export const addKeyword = (keyword) => {
    return request.get('/search/addKeywordToHistory?keyword=' + keyword)
}

/**
 * 热搜统计
 * @param data
 * @returns
 */
export const hotSearchCount = (limitCount?) => {
    return request.get('/search/hotSearchCount?limitCount=' + limitCount)
}

/**
 * 我的搜索历史
 * @param data
 * @returns
 */
export const mySearchHistory = () => {
    return request.get('/search/mySearchHistory')
}
